package sqlToGUI.testing.sendingInput;

import java.util.LinkedList;

public class CarDataCreator extends DataCreator{

	private LinkedList <Character>buff;

	private int direction = 1000;
	private int distance = 1000;
	
	private String directionS;
	private String distanceS;
	
	public CarDataCreator(LinkedList <Character>buff){
		this.buff = buff;
	}
	
	public void update(){

		direction = 1000;
		distance = 1000;
		
		directionS = fixDataLength(direction + "", inputLength);
		distanceS = fixDataLength(distance + "", inputLength);
		
		
		
		buff.add('$'); buff.add('#');
		buff.add('9'); buff.add('5');
		buff.add(directionS.charAt(0));
		buff.add(directionS.charAt(1));
		buff.add(directionS.charAt(2));
		buff.add(directionS.charAt(3));
		
		buff.add('$'); buff.add('#');
		buff.add('9'); buff.add('6');
		buff.add(distanceS.charAt(0));
		buff.add(distanceS.charAt(1));
		buff.add(distanceS.charAt(2));
		buff.add(distanceS.charAt(3));
	}
}